package com.distributer.report.domain.common;

import java.io.Serializable;
import java.util.UUID;

public class Entry implements Serializable{

	private static final long serialVersionUID = -6781305043780520029L;
	
	private String id;

	public Entry(){
		this.id = UUID.randomUUID().toString().replace("-", "");
	}
	
	public String getId() {
		return id;
	}

	public void setId(String id) {
		this.id = id;
	}
	
	@Override
	public boolean equals(Object obj) {
		if (this == obj) {
			return true;
		}
		if (!(obj instanceof Entry)) {
			return false;
		}
		Entry compareObj = (Entry)obj;
		
		return this.id.toString().equals(compareObj.getId());
	}
	
	@Override
	public int hashCode() {
		return this.id.hashCode();
	}
}
